(0) Obligation:

Clauses:

ordered([]) :- !.
ordered(.(X1, [])) :- !.
ordered(Xs) :- ','(head(Xs, X), ','(tail(Xs, Ys), ','(head(Ys, Y), ','(tail(Ys, Zs), ','(less(X, s(Y)), ordered(.(Y, Zs))))))).
head([], X2).
head(.(X, X3), X).
tail([], []).
tail(.(X4, Xs), Xs).
less(0, Y) :- ','(!, eq(Y, s(X5))).
less(X, Y) :- ','(p(X, Px), ','(p(Y, Py), less(Px, Py))).
p(0, 0).
p(s(X), X).
eq(X, X).

Query: ordered(g)

(1) PrologToPrologProblemTransformerProof (SOUND transformation)

Built Prolog problem from termination graph ICLP10.

(2) Obligation:

Clauses:

lessA(s(T77)) :- lessA(T77).
lessB(0, s(T62)).
lessB(s(T71), 0) :- lessA(T71).
lessB(s(T71), s(T80)) :- lessB(T71, T80).
lessC(0, T39).
lessC(s(T48), T52) :- lessB(T48, T52).
orderedD([]).
orderedD(.(T3, [])).
orderedD(.(T16, .(T30, T31))) :- lessC(T16, T30).
orderedD(.(T16, .(T30, T31))) :- ','(lessC(T16, T30), orderedD(.(T30, T31))).

Query: orderedD(g)

(3) PrologToPiTRSProof (SOUND transformation)

We use the technique of [TOCL09]. With regard to the inferred argument filtering the predicates were used in the following modes:
orderedD_in: (b)
lessC_in: (b,b)
lessB_in: (b,b)
lessA_in: (b)
Transforming Prolog into the following Term Rewriting System:
Pi-finite rewrite system:
The TRS R consists of the following rules:

orderedD_in_g([]) → orderedD_out_g([])
orderedD_in_g(.(T3, [])) → orderedD_out_g(.(T3, []))
orderedD_in_g(.(T16, .(T30, T31))) → U5_g(T16, T30, T31, lessC_in_gg(T16, T30))
lessC_in_gg(0, T39) → lessC_out_gg(0, T39)
lessC_in_gg(s(T48), T52) → U4_gg(T48, T52, lessB_in_gg(T48, T52))
lessB_in_gg(0, s(T62)) → lessB_out_gg(0, s(T62))
lessB_in_gg(s(T71), 0) → U2_gg(T71, lessA_in_g(T71))
lessA_in_g(s(T77)) → U1_g(T77, lessA_in_g(T77))
U1_g(T77, lessA_out_g(T77)) → lessA_out_g(s(T77))
U2_gg(T71, lessA_out_g(T71)) → lessB_out_gg(s(T71), 0)
lessB_in_gg(s(T71), s(T80)) → U3_gg(T71, T80, lessB_in_gg(T71, T80))
U3_gg(T71, T80, lessB_out_gg(T71, T80)) → lessB_out_gg(s(T71), s(T80))
U4_gg(T48, T52, lessB_out_gg(T48, T52)) → lessC_out_gg(s(T48), T52)
U5_g(T16, T30, T31, lessC_out_gg(T16, T30)) → orderedD_out_g(.(T16, .(T30, T31)))
U5_g(T16, T30, T31, lessC_out_gg(T16, T30)) → U6_g(T16, T30, T31, orderedD_in_g(.(T30, T31)))
U6_g(T16, T30, T31, orderedD_out_g(.(T30, T31))) → orderedD_out_g(.(T16, .(T30, T31)))

The argument filtering Pi contains the following mapping:
orderedD_in_g(x1)  =  orderedD_in_g(x1)
[]  =  []
orderedD_out_g(x1)  =  orderedD_out_g
.(x1, x2)  =  .(x1, x2)
U5_g(x1, x2, x3, x4)  =  U5_g(x2, x3, x4)
lessC_in_gg(x1, x2)  =  lessC_in_gg(x1, x2)
0  =  0
lessC_out_gg(x1, x2)  =  lessC_out_gg
s(x1)  =  s(x1)
U4_gg(x1, x2, x3)  =  U4_gg(x3)
lessB_in_gg(x1, x2)  =  lessB_in_gg(x1, x2)
lessB_out_gg(x1, x2)  =  lessB_out_gg
U2_gg(x1, x2)  =  U2_gg(x2)
lessA_in_g(x1)  =  lessA_in_g(x1)
U1_g(x1, x2)  =  U1_g(x2)
lessA_out_g(x1)  =  lessA_out_g
U3_gg(x1, x2, x3)  =  U3_gg(x3)
U6_g(x1, x2, x3, x4)  =  U6_g(x4)

Infinitary Constructor Rewriting Termination of PiTRS implies Termination of Prolog

(4) Obligation:

Pi-finite rewrite system:
The TRS R consists of the following rules:

orderedD_in_g([]) → orderedD_out_g([])
orderedD_in_g(.(T3, [])) → orderedD_out_g(.(T3, []))
orderedD_in_g(.(T16, .(T30, T31))) → U5_g(T16, T30, T31, lessC_in_gg(T16, T30))
lessC_in_gg(0, T39) → lessC_out_gg(0, T39)
lessC_in_gg(s(T48), T52) → U4_gg(T48, T52, lessB_in_gg(T48, T52))
lessB_in_gg(0, s(T62)) → lessB_out_gg(0, s(T62))
lessB_in_gg(s(T71), 0) → U2_gg(T71, lessA_in_g(T71))
lessA_in_g(s(T77)) → U1_g(T77, lessA_in_g(T77))
U1_g(T77, lessA_out_g(T77)) → lessA_out_g(s(T77))
U2_gg(T71, lessA_out_g(T71)) → lessB_out_gg(s(T71), 0)
lessB_in_gg(s(T71), s(T80)) → U3_gg(T71, T80, lessB_in_gg(T71, T80))
U3_gg(T71, T80, lessB_out_gg(T71, T80)) → lessB_out_gg(s(T71), s(T80))
U4_gg(T48, T52, lessB_out_gg(T48, T52)) → lessC_out_gg(s(T48), T52)
U5_g(T16, T30, T31, lessC_out_gg(T16, T30)) → orderedD_out_g(.(T16, .(T30, T31)))
U5_g(T16, T30, T31, lessC_out_gg(T16, T30)) → U6_g(T16, T30, T31, orderedD_in_g(.(T30, T31)))
U6_g(T16, T30, T31, orderedD_out_g(.(T30, T31))) → orderedD_out_g(.(T16, .(T30, T31)))

The argument filtering Pi contains the following mapping:
orderedD_in_g(x1)  =  orderedD_in_g(x1)
[]  =  []
orderedD_out_g(x1)  =  orderedD_out_g
.(x1, x2)  =  .(x1, x2)
U5_g(x1, x2, x3, x4)  =  U5_g(x2, x3, x4)
lessC_in_gg(x1, x2)  =  lessC_in_gg(x1, x2)
0  =  0
lessC_out_gg(x1, x2)  =  lessC_out_gg
s(x1)  =  s(x1)
U4_gg(x1, x2, x3)  =  U4_gg(x3)
lessB_in_gg(x1, x2)  =  lessB_in_gg(x1, x2)
lessB_out_gg(x1, x2)  =  lessB_out_gg
U2_gg(x1, x2)  =  U2_gg(x2)
lessA_in_g(x1)  =  lessA_in_g(x1)
U1_g(x1, x2)  =  U1_g(x2)
lessA_out_g(x1)  =  lessA_out_g
U3_gg(x1, x2, x3)  =  U3_gg(x3)
U6_g(x1, x2, x3, x4)  =  U6_g(x4)

(5) DependencyPairsProof (EQUIVALENT transformation)

Using Dependency Pairs [AG00,LOPSTR] we result in the following initial DP problem:
Pi DP problem:
The TRS P consists of the following rules:

ORDEREDD_IN_G(.(T16, .(T30, T31))) → U5_G(T16, T30, T31, lessC_in_gg(T16, T30))
ORDEREDD_IN_G(.(T16, .(T30, T31))) → LESSC_IN_GG(T16, T30)
LESSC_IN_GG(s(T48), T52) → U4_GG(T48, T52, lessB_in_gg(T48, T52))
LESSC_IN_GG(s(T48), T52) → LESSB_IN_GG(T48, T52)
LESSB_IN_GG(s(T71), 0) → U2_GG(T71, lessA_in_g(T71))
LESSB_IN_GG(s(T71), 0) → LESSA_IN_G(T71)
LESSA_IN_G(s(T77)) → U1_G(T77, lessA_in_g(T77))
LESSA_IN_G(s(T77)) → LESSA_IN_G(T77)
LESSB_IN_GG(s(T71), s(T80)) → U3_GG(T71, T80, lessB_in_gg(T71, T80))
LESSB_IN_GG(s(T71), s(T80)) → LESSB_IN_GG(T71, T80)
U5_G(T16, T30, T31, lessC_out_gg(T16, T30)) → U6_G(T16, T30, T31, orderedD_in_g(.(T30, T31)))
U5_G(T16, T30, T31, lessC_out_gg(T16, T30)) → ORDEREDD_IN_G(.(T30, T31))

The TRS R consists of the following rules:

orderedD_in_g([]) → orderedD_out_g([])
orderedD_in_g(.(T3, [])) → orderedD_out_g(.(T3, []))
orderedD_in_g(.(T16, .(T30, T31))) → U5_g(T16, T30, T31, lessC_in_gg(T16, T30))
lessC_in_gg(0, T39) → lessC_out_gg(0, T39)
lessC_in_gg(s(T48), T52) → U4_gg(T48, T52, lessB_in_gg(T48, T52))
lessB_in_gg(0, s(T62)) → lessB_out_gg(0, s(T62))
lessB_in_gg(s(T71), 0) → U2_gg(T71, lessA_in_g(T71))
lessA_in_g(s(T77)) → U1_g(T77, lessA_in_g(T77))
U1_g(T77, lessA_out_g(T77)) → lessA_out_g(s(T77))
U2_gg(T71, lessA_out_g(T71)) → lessB_out_gg(s(T71), 0)
lessB_in_gg(s(T71), s(T80)) → U3_gg(T71, T80, lessB_in_gg(T71, T80))
U3_gg(T71, T80, lessB_out_gg(T71, T80)) → lessB_out_gg(s(T71), s(T80))
U4_gg(T48, T52, lessB_out_gg(T48, T52)) → lessC_out_gg(s(T48), T52)
U5_g(T16, T30, T31, lessC_out_gg(T16, T30)) → orderedD_out_g(.(T16, .(T30, T31)))
U5_g(T16, T30, T31, lessC_out_gg(T16, T30)) → U6_g(T16, T30, T31, orderedD_in_g(.(T30, T31)))
U6_g(T16, T30, T31, orderedD_out_g(.(T30, T31))) → orderedD_out_g(.(T16, .(T30, T31)))

The argument filtering Pi contains the following mapping:
orderedD_in_g(x1)  =  orderedD_in_g(x1)
[]  =  []
orderedD_out_g(x1)  =  orderedD_out_g
.(x1, x2)  =  .(x1, x2)
U5_g(x1, x2, x3, x4)  =  U5_g(x2, x3, x4)
lessC_in_gg(x1, x2)  =  lessC_in_gg(x1, x2)
0  =  0
lessC_out_gg(x1, x2)  =  lessC_out_gg
s(x1)  =  s(x1)
U4_gg(x1, x2, x3)  =  U4_gg(x3)
lessB_in_gg(x1, x2)  =  lessB_in_gg(x1, x2)
lessB_out_gg(x1, x2)  =  lessB_out_gg
U2_gg(x1, x2)  =  U2_gg(x2)
lessA_in_g(x1)  =  lessA_in_g(x1)
U1_g(x1, x2)  =  U1_g(x2)
lessA_out_g(x1)  =  lessA_out_g
U3_gg(x1, x2, x3)  =  U3_gg(x3)
U6_g(x1, x2, x3, x4)  =  U6_g(x4)
ORDEREDD_IN_G(x1)  =  ORDEREDD_IN_G(x1)
U5_G(x1, x2, x3, x4)  =  U5_G(x2, x3, x4)
LESSC_IN_GG(x1, x2)  =  LESSC_IN_GG(x1, x2)
U4_GG(x1, x2, x3)  =  U4_GG(x3)
LESSB_IN_GG(x1, x2)  =  LESSB_IN_GG(x1, x2)
U2_GG(x1, x2)  =  U2_GG(x2)
LESSA_IN_G(x1)  =  LESSA_IN_G(x1)
U1_G(x1, x2)  =  U1_G(x2)
U3_GG(x1, x2, x3)  =  U3_GG(x3)
U6_G(x1, x2, x3, x4)  =  U6_G(x4)

We have to consider all (P,R,Pi)-chains

(6) Obligation:

Pi DP problem:
The TRS P consists of the following rules:

ORDEREDD_IN_G(.(T16, .(T30, T31))) → U5_G(T16, T30, T31, lessC_in_gg(T16, T30))
ORDEREDD_IN_G(.(T16, .(T30, T31))) → LESSC_IN_GG(T16, T30)
LESSC_IN_GG(s(T48), T52) → U4_GG(T48, T52, lessB_in_gg(T48, T52))
LESSC_IN_GG(s(T48), T52) → LESSB_IN_GG(T48, T52)
LESSB_IN_GG(s(T71), 0) → U2_GG(T71, lessA_in_g(T71))
LESSB_IN_GG(s(T71), 0) → LESSA_IN_G(T71)
LESSA_IN_G(s(T77)) → U1_G(T77, lessA_in_g(T77))
LESSA_IN_G(s(T77)) → LESSA_IN_G(T77)
LESSB_IN_GG(s(T71), s(T80)) → U3_GG(T71, T80, lessB_in_gg(T71, T80))
LESSB_IN_GG(s(T71), s(T80)) → LESSB_IN_GG(T71, T80)
U5_G(T16, T30, T31, lessC_out_gg(T16, T30)) → U6_G(T16, T30, T31, orderedD_in_g(.(T30, T31)))
U5_G(T16, T30, T31, lessC_out_gg(T16, T30)) → ORDEREDD_IN_G(.(T30, T31))

The TRS R consists of the following rules:

orderedD_in_g([]) → orderedD_out_g([])
orderedD_in_g(.(T3, [])) → orderedD_out_g(.(T3, []))
orderedD_in_g(.(T16, .(T30, T31))) → U5_g(T16, T30, T31, lessC_in_gg(T16, T30))
lessC_in_gg(0, T39) → lessC_out_gg(0, T39)
lessC_in_gg(s(T48), T52) → U4_gg(T48, T52, lessB_in_gg(T48, T52))
lessB_in_gg(0, s(T62)) → lessB_out_gg(0, s(T62))
lessB_in_gg(s(T71), 0) → U2_gg(T71, lessA_in_g(T71))
lessA_in_g(s(T77)) → U1_g(T77, lessA_in_g(T77))
U1_g(T77, lessA_out_g(T77)) → lessA_out_g(s(T77))
U2_gg(T71, lessA_out_g(T71)) → lessB_out_gg(s(T71), 0)
lessB_in_gg(s(T71), s(T80)) → U3_gg(T71, T80, lessB_in_gg(T71, T80))
U3_gg(T71, T80, lessB_out_gg(T71, T80)) → lessB_out_gg(s(T71), s(T80))
U4_gg(T48, T52, lessB_out_gg(T48, T52)) → lessC_out_gg(s(T48), T52)
U5_g(T16, T30, T31, lessC_out_gg(T16, T30)) → orderedD_out_g(.(T16, .(T30, T31)))
U5_g(T16, T30, T31, lessC_out_gg(T16, T30)) → U6_g(T16, T30, T31, orderedD_in_g(.(T30, T31)))
U6_g(T16, T30, T31, orderedD_out_g(.(T30, T31))) → orderedD_out_g(.(T16, .(T30, T31)))

The argument filtering Pi contains the following mapping:
orderedD_in_g(x1)  =  orderedD_in_g(x1)
[]  =  []
orderedD_out_g(x1)  =  orderedD_out_g
.(x1, x2)  =  .(x1, x2)
U5_g(x1, x2, x3, x4)  =  U5_g(x2, x3, x4)
lessC_in_gg(x1, x2)  =  lessC_in_gg(x1, x2)
0  =  0
lessC_out_gg(x1, x2)  =  lessC_out_gg
s(x1)  =  s(x1)
U4_gg(x1, x2, x3)  =  U4_gg(x3)
lessB_in_gg(x1, x2)  =  lessB_in_gg(x1, x2)
lessB_out_gg(x1, x2)  =  lessB_out_gg
U2_gg(x1, x2)  =  U2_gg(x2)
lessA_in_g(x1)  =  lessA_in_g(x1)
U1_g(x1, x2)  =  U1_g(x2)
lessA_out_g(x1)  =  lessA_out_g
U3_gg(x1, x2, x3)  =  U3_gg(x3)
U6_g(x1, x2, x3, x4)  =  U6_g(x4)
ORDEREDD_IN_G(x1)  =  ORDEREDD_IN_G(x1)
U5_G(x1, x2, x3, x4)  =  U5_G(x2, x3, x4)
LESSC_IN_GG(x1, x2)  =  LESSC_IN_GG(x1, x2)
U4_GG(x1, x2, x3)  =  U4_GG(x3)
LESSB_IN_GG(x1, x2)  =  LESSB_IN_GG(x1, x2)
U2_GG(x1, x2)  =  U2_GG(x2)
LESSA_IN_G(x1)  =  LESSA_IN_G(x1)
U1_G(x1, x2)  =  U1_G(x2)
U3_GG(x1, x2, x3)  =  U3_GG(x3)
U6_G(x1, x2, x3, x4)  =  U6_G(x4)

We have to consider all (P,R,Pi)-chains

(7) DependencyGraphProof (EQUIVALENT transformation)

The approximation of the Dependency Graph [LOPSTR] contains 3 SCCs with 8 less nodes.

(8) Complex Obligation (AND)

(9) Obligation:

Pi DP problem:
The TRS P consists of the following rules:

LESSA_IN_G(s(T77)) → LESSA_IN_G(T77)

The TRS R consists of the following rules:

orderedD_in_g([]) → orderedD_out_g([])
orderedD_in_g(.(T3, [])) → orderedD_out_g(.(T3, []))
orderedD_in_g(.(T16, .(T30, T31))) → U5_g(T16, T30, T31, lessC_in_gg(T16, T30))
lessC_in_gg(0, T39) → lessC_out_gg(0, T39)
lessC_in_gg(s(T48), T52) → U4_gg(T48, T52, lessB_in_gg(T48, T52))
lessB_in_gg(0, s(T62)) → lessB_out_gg(0, s(T62))
lessB_in_gg(s(T71), 0) → U2_gg(T71, lessA_in_g(T71))
lessA_in_g(s(T77)) → U1_g(T77, lessA_in_g(T77))
U1_g(T77, lessA_out_g(T77)) → lessA_out_g(s(T77))
U2_gg(T71, lessA_out_g(T71)) → lessB_out_gg(s(T71), 0)
lessB_in_gg(s(T71), s(T80)) → U3_gg(T71, T80, lessB_in_gg(T71, T80))
U3_gg(T71, T80, lessB_out_gg(T71, T80)) → lessB_out_gg(s(T71), s(T80))
U4_gg(T48, T52, lessB_out_gg(T48, T52)) → lessC_out_gg(s(T48), T52)
U5_g(T16, T30, T31, lessC_out_gg(T16, T30)) → orderedD_out_g(.(T16, .(T30, T31)))
U5_g(T16, T30, T31, lessC_out_gg(T16, T30)) → U6_g(T16, T30, T31, orderedD_in_g(.(T30, T31)))
U6_g(T16, T30, T31, orderedD_out_g(.(T30, T31))) → orderedD_out_g(.(T16, .(T30, T31)))

The argument filtering Pi contains the following mapping:
orderedD_in_g(x1)  =  orderedD_in_g(x1)
[]  =  []
orderedD_out_g(x1)  =  orderedD_out_g
.(x1, x2)  =  .(x1, x2)
U5_g(x1, x2, x3, x4)  =  U5_g(x2, x3, x4)
lessC_in_gg(x1, x2)  =  lessC_in_gg(x1, x2)
0  =  0
lessC_out_gg(x1, x2)  =  lessC_out_gg
s(x1)  =  s(x1)
U4_gg(x1, x2, x3)  =  U4_gg(x3)
lessB_in_gg(x1, x2)  =  lessB_in_gg(x1, x2)
lessB_out_gg(x1, x2)  =  lessB_out_gg
U2_gg(x1, x2)  =  U2_gg(x2)
lessA_in_g(x1)  =  lessA_in_g(x1)
U1_g(x1, x2)  =  U1_g(x2)
lessA_out_g(x1)  =  lessA_out_g
U3_gg(x1, x2, x3)  =  U3_gg(x3)
U6_g(x1, x2, x3, x4)  =  U6_g(x4)
LESSA_IN_G(x1)  =  LESSA_IN_G(x1)

We have to consider all (P,R,Pi)-chains

(10) UsableRulesProof (EQUIVALENT transformation)

For (infinitary) constructor rewriting [LOPSTR] we can delete all non-usable rules from R.

(11) Obligation:

Pi DP problem:
The TRS P consists of the following rules:

LESSA_IN_G(s(T77)) → LESSA_IN_G(T77)

R is empty.
Pi is empty.
We have to consider all (P,R,Pi)-chains

(12) PiDPToQDPProof (EQUIVALENT transformation)

Transforming (infinitary) constructor rewriting Pi-DP problem [LOPSTR] into ordinary QDP problem [LPAR04] by application of Pi.

(13) Obligation:

Q DP problem:
The TRS P consists of the following rules:

LESSA_IN_G(s(T77)) → LESSA_IN_G(T77)

R is empty.
Q is empty.
We have to consider all (P,Q,R)-chains.

(14) QDPSizeChangeProof (EQUIVALENT transformation)

By using the subterm criterion [SUBTERM_CRITERION] together with the size-change analysis [AAECC05] we have proven that there are no infinite chains for this DP problem.

From the DPs we obtained the following set of size-change graphs:

  • LESSA_IN_G(s(T77)) → LESSA_IN_G(T77)
    The graph contains the following edges 1 > 1

(15) YES

(16) Obligation:

Pi DP problem:
The TRS P consists of the following rules:

LESSB_IN_GG(s(T71), s(T80)) → LESSB_IN_GG(T71, T80)

The TRS R consists of the following rules:

orderedD_in_g([]) → orderedD_out_g([])
orderedD_in_g(.(T3, [])) → orderedD_out_g(.(T3, []))
orderedD_in_g(.(T16, .(T30, T31))) → U5_g(T16, T30, T31, lessC_in_gg(T16, T30))
lessC_in_gg(0, T39) → lessC_out_gg(0, T39)
lessC_in_gg(s(T48), T52) → U4_gg(T48, T52, lessB_in_gg(T48, T52))
lessB_in_gg(0, s(T62)) → lessB_out_gg(0, s(T62))
lessB_in_gg(s(T71), 0) → U2_gg(T71, lessA_in_g(T71))
lessA_in_g(s(T77)) → U1_g(T77, lessA_in_g(T77))
U1_g(T77, lessA_out_g(T77)) → lessA_out_g(s(T77))
U2_gg(T71, lessA_out_g(T71)) → lessB_out_gg(s(T71), 0)
lessB_in_gg(s(T71), s(T80)) → U3_gg(T71, T80, lessB_in_gg(T71, T80))
U3_gg(T71, T80, lessB_out_gg(T71, T80)) → lessB_out_gg(s(T71), s(T80))
U4_gg(T48, T52, lessB_out_gg(T48, T52)) → lessC_out_gg(s(T48), T52)
U5_g(T16, T30, T31, lessC_out_gg(T16, T30)) → orderedD_out_g(.(T16, .(T30, T31)))
U5_g(T16, T30, T31, lessC_out_gg(T16, T30)) → U6_g(T16, T30, T31, orderedD_in_g(.(T30, T31)))
U6_g(T16, T30, T31, orderedD_out_g(.(T30, T31))) → orderedD_out_g(.(T16, .(T30, T31)))

The argument filtering Pi contains the following mapping:
orderedD_in_g(x1)  =  orderedD_in_g(x1)
[]  =  []
orderedD_out_g(x1)  =  orderedD_out_g
.(x1, x2)  =  .(x1, x2)
U5_g(x1, x2, x3, x4)  =  U5_g(x2, x3, x4)
lessC_in_gg(x1, x2)  =  lessC_in_gg(x1, x2)
0  =  0
lessC_out_gg(x1, x2)  =  lessC_out_gg
s(x1)  =  s(x1)
U4_gg(x1, x2, x3)  =  U4_gg(x3)
lessB_in_gg(x1, x2)  =  lessB_in_gg(x1, x2)
lessB_out_gg(x1, x2)  =  lessB_out_gg
U2_gg(x1, x2)  =  U2_gg(x2)
lessA_in_g(x1)  =  lessA_in_g(x1)
U1_g(x1, x2)  =  U1_g(x2)
lessA_out_g(x1)  =  lessA_out_g
U3_gg(x1, x2, x3)  =  U3_gg(x3)
U6_g(x1, x2, x3, x4)  =  U6_g(x4)
LESSB_IN_GG(x1, x2)  =  LESSB_IN_GG(x1, x2)

We have to consider all (P,R,Pi)-chains

(17) UsableRulesProof (EQUIVALENT transformation)

For (infinitary) constructor rewriting [LOPSTR] we can delete all non-usable rules from R.

(18) Obligation:

Pi DP problem:
The TRS P consists of the following rules:

LESSB_IN_GG(s(T71), s(T80)) → LESSB_IN_GG(T71, T80)

R is empty.
Pi is empty.
We have to consider all (P,R,Pi)-chains

(19) PiDPToQDPProof (EQUIVALENT transformation)

Transforming (infinitary) constructor rewriting Pi-DP problem [LOPSTR] into ordinary QDP problem [LPAR04] by application of Pi.

(20) Obligation:

Q DP problem:
The TRS P consists of the following rules:

LESSB_IN_GG(s(T71), s(T80)) → LESSB_IN_GG(T71, T80)

R is empty.
Q is empty.
We have to consider all (P,Q,R)-chains.

(21) QDPSizeChangeProof (EQUIVALENT transformation)

By using the subterm criterion [SUBTERM_CRITERION] together with the size-change analysis [AAECC05] we have proven that there are no infinite chains for this DP problem.

From the DPs we obtained the following set of size-change graphs:

  • LESSB_IN_GG(s(T71), s(T80)) → LESSB_IN_GG(T71, T80)
    The graph contains the following edges 1 > 1, 2 > 2

(22) YES

(23) Obligation:

Pi DP problem:
The TRS P consists of the following rules:

U5_G(T16, T30, T31, lessC_out_gg(T16, T30)) → ORDEREDD_IN_G(.(T30, T31))
ORDEREDD_IN_G(.(T16, .(T30, T31))) → U5_G(T16, T30, T31, lessC_in_gg(T16, T30))

The TRS R consists of the following rules:

orderedD_in_g([]) → orderedD_out_g([])
orderedD_in_g(.(T3, [])) → orderedD_out_g(.(T3, []))
orderedD_in_g(.(T16, .(T30, T31))) → U5_g(T16, T30, T31, lessC_in_gg(T16, T30))
lessC_in_gg(0, T39) → lessC_out_gg(0, T39)
lessC_in_gg(s(T48), T52) → U4_gg(T48, T52, lessB_in_gg(T48, T52))
lessB_in_gg(0, s(T62)) → lessB_out_gg(0, s(T62))
lessB_in_gg(s(T71), 0) → U2_gg(T71, lessA_in_g(T71))
lessA_in_g(s(T77)) → U1_g(T77, lessA_in_g(T77))
U1_g(T77, lessA_out_g(T77)) → lessA_out_g(s(T77))
U2_gg(T71, lessA_out_g(T71)) → lessB_out_gg(s(T71), 0)
lessB_in_gg(s(T71), s(T80)) → U3_gg(T71, T80, lessB_in_gg(T71, T80))
U3_gg(T71, T80, lessB_out_gg(T71, T80)) → lessB_out_gg(s(T71), s(T80))
U4_gg(T48, T52, lessB_out_gg(T48, T52)) → lessC_out_gg(s(T48), T52)
U5_g(T16, T30, T31, lessC_out_gg(T16, T30)) → orderedD_out_g(.(T16, .(T30, T31)))
U5_g(T16, T30, T31, lessC_out_gg(T16, T30)) → U6_g(T16, T30, T31, orderedD_in_g(.(T30, T31)))
U6_g(T16, T30, T31, orderedD_out_g(.(T30, T31))) → orderedD_out_g(.(T16, .(T30, T31)))

The argument filtering Pi contains the following mapping:
orderedD_in_g(x1)  =  orderedD_in_g(x1)
[]  =  []
orderedD_out_g(x1)  =  orderedD_out_g
.(x1, x2)  =  .(x1, x2)
U5_g(x1, x2, x3, x4)  =  U5_g(x2, x3, x4)
lessC_in_gg(x1, x2)  =  lessC_in_gg(x1, x2)
0  =  0
lessC_out_gg(x1, x2)  =  lessC_out_gg
s(x1)  =  s(x1)
U4_gg(x1, x2, x3)  =  U4_gg(x3)
lessB_in_gg(x1, x2)  =  lessB_in_gg(x1, x2)
lessB_out_gg(x1, x2)  =  lessB_out_gg
U2_gg(x1, x2)  =  U2_gg(x2)
lessA_in_g(x1)  =  lessA_in_g(x1)
U1_g(x1, x2)  =  U1_g(x2)
lessA_out_g(x1)  =  lessA_out_g
U3_gg(x1, x2, x3)  =  U3_gg(x3)
U6_g(x1, x2, x3, x4)  =  U6_g(x4)
ORDEREDD_IN_G(x1)  =  ORDEREDD_IN_G(x1)
U5_G(x1, x2, x3, x4)  =  U5_G(x2, x3, x4)

We have to consider all (P,R,Pi)-chains

(24) UsableRulesProof (EQUIVALENT transformation)

For (infinitary) constructor rewriting [LOPSTR] we can delete all non-usable rules from R.

(25) Obligation:

Pi DP problem:
The TRS P consists of the following rules:

U5_G(T16, T30, T31, lessC_out_gg(T16, T30)) → ORDEREDD_IN_G(.(T30, T31))
ORDEREDD_IN_G(.(T16, .(T30, T31))) → U5_G(T16, T30, T31, lessC_in_gg(T16, T30))

The TRS R consists of the following rules:

lessC_in_gg(0, T39) → lessC_out_gg(0, T39)
lessC_in_gg(s(T48), T52) → U4_gg(T48, T52, lessB_in_gg(T48, T52))
U4_gg(T48, T52, lessB_out_gg(T48, T52)) → lessC_out_gg(s(T48), T52)
lessB_in_gg(0, s(T62)) → lessB_out_gg(0, s(T62))
lessB_in_gg(s(T71), 0) → U2_gg(T71, lessA_in_g(T71))
lessB_in_gg(s(T71), s(T80)) → U3_gg(T71, T80, lessB_in_gg(T71, T80))
U2_gg(T71, lessA_out_g(T71)) → lessB_out_gg(s(T71), 0)
U3_gg(T71, T80, lessB_out_gg(T71, T80)) → lessB_out_gg(s(T71), s(T80))
lessA_in_g(s(T77)) → U1_g(T77, lessA_in_g(T77))
U1_g(T77, lessA_out_g(T77)) → lessA_out_g(s(T77))

The argument filtering Pi contains the following mapping:
.(x1, x2)  =  .(x1, x2)
lessC_in_gg(x1, x2)  =  lessC_in_gg(x1, x2)
0  =  0
lessC_out_gg(x1, x2)  =  lessC_out_gg
s(x1)  =  s(x1)
U4_gg(x1, x2, x3)  =  U4_gg(x3)
lessB_in_gg(x1, x2)  =  lessB_in_gg(x1, x2)
lessB_out_gg(x1, x2)  =  lessB_out_gg
U2_gg(x1, x2)  =  U2_gg(x2)
lessA_in_g(x1)  =  lessA_in_g(x1)
U1_g(x1, x2)  =  U1_g(x2)
lessA_out_g(x1)  =  lessA_out_g
U3_gg(x1, x2, x3)  =  U3_gg(x3)
ORDEREDD_IN_G(x1)  =  ORDEREDD_IN_G(x1)
U5_G(x1, x2, x3, x4)  =  U5_G(x2, x3, x4)

We have to consider all (P,R,Pi)-chains

(26) PiDPToQDPProof (SOUND transformation)

Transforming (infinitary) constructor rewriting Pi-DP problem [LOPSTR] into ordinary QDP problem [LPAR04] by application of Pi.

(27) Obligation:

Q DP problem:
The TRS P consists of the following rules:

U5_G(T30, T31, lessC_out_gg) → ORDEREDD_IN_G(.(T30, T31))
ORDEREDD_IN_G(.(T16, .(T30, T31))) → U5_G(T30, T31, lessC_in_gg(T16, T30))

The TRS R consists of the following rules:

lessC_in_gg(0, T39) → lessC_out_gg
lessC_in_gg(s(T48), T52) → U4_gg(lessB_in_gg(T48, T52))
U4_gg(lessB_out_gg) → lessC_out_gg
lessB_in_gg(0, s(T62)) → lessB_out_gg
lessB_in_gg(s(T71), 0) → U2_gg(lessA_in_g(T71))
lessB_in_gg(s(T71), s(T80)) → U3_gg(lessB_in_gg(T71, T80))
U2_gg(lessA_out_g) → lessB_out_gg
U3_gg(lessB_out_gg) → lessB_out_gg
lessA_in_g(s(T77)) → U1_g(lessA_in_g(T77))
U1_g(lessA_out_g) → lessA_out_g

The set Q consists of the following terms:

lessC_in_gg(x0, x1)
U4_gg(x0)
lessB_in_gg(x0, x1)
U2_gg(x0)
U3_gg(x0)
lessA_in_g(x0)
U1_g(x0)

We have to consider all (P,Q,R)-chains.

(28) UsableRulesReductionPairsProof (EQUIVALENT transformation)

By using the usable rules with reduction pair processor [LPAR04] with a polynomial ordering [POLO], all dependency pairs and the corresponding usable rules [FROCOS05] can be oriented non-strictly. All non-usable rules are removed, and those dependency pairs and usable rules that have been oriented strictly or contain non-usable symbols in their left-hand side are removed as well.

The following dependency pairs can be deleted:

ORDEREDD_IN_G(.(T16, .(T30, T31))) → U5_G(T30, T31, lessC_in_gg(T16, T30))
The following rules are removed from R:

lessC_in_gg(0, T39) → lessC_out_gg
lessC_in_gg(s(T48), T52) → U4_gg(lessB_in_gg(T48, T52))
U4_gg(lessB_out_gg) → lessC_out_gg
lessB_in_gg(0, s(T62)) → lessB_out_gg
lessB_in_gg(s(T71), 0) → U2_gg(lessA_in_g(T71))
lessB_in_gg(s(T71), s(T80)) → U3_gg(lessB_in_gg(T71, T80))
U2_gg(lessA_out_g) → lessB_out_gg
U3_gg(lessB_out_gg) → lessB_out_gg
lessA_in_g(s(T77)) → U1_g(lessA_in_g(T77))
Used ordering: POLO with Polynomial interpretation [POLO]:

POL(.(x1, x2)) = 1 + x1 + 2·x2   
POL(0) = 0   
POL(ORDEREDD_IN_G(x1)) = x1   
POL(U1_g(x1)) = x1   
POL(U2_gg(x1)) = 1 + 2·x1   
POL(U3_gg(x1)) = 2 + 2·x1   
POL(U4_gg(x1)) = 1 + x1   
POL(U5_G(x1, x2, x3)) = 1 + x1 + 2·x2 + x3   
POL(lessA_in_g(x1)) = 1 + x1   
POL(lessA_out_g) = 2   
POL(lessB_in_gg(x1, x2)) = 1 + 2·x1 + x2   
POL(lessB_out_gg) = 1   
POL(lessC_in_gg(x1, x2)) = 1 + x1 + x2   
POL(lessC_out_gg) = 0   
POL(s(x1)) = 1 + 2·x1   

(29) Obligation:

Q DP problem:
The TRS P consists of the following rules:

U5_G(T30, T31, lessC_out_gg) → ORDEREDD_IN_G(.(T30, T31))

The TRS R consists of the following rules:

U1_g(lessA_out_g) → lessA_out_g

The set Q consists of the following terms:

lessC_in_gg(x0, x1)
U4_gg(x0)
lessB_in_gg(x0, x1)
U2_gg(x0)
U3_gg(x0)
lessA_in_g(x0)
U1_g(x0)

We have to consider all (P,Q,R)-chains.

(30) DependencyGraphProof (EQUIVALENT transformation)

The approximation of the Dependency Graph [LPAR04,FROCOS05,EDGSTAR] contains 0 SCCs with 1 less node.

(31) TRUE